package com.qianxing.exceptionhandler;

/**
 * Author:JasonLong
 * Date:2023/5/11
 * Time:17:04
 * 异常枚举类
 */
public enum EnumException {

    SUCCESS("200", "成功!"),

    BAD_REQUEST("400", "参数错误，请检查参数格式是否正确！"),

    NOT_FOUND("404", "找不到资源!"),

    INTERNAL_SERVER_ERROR("500", "服务器繁忙!"),

    NULL_POINT("505", "空指针异常！");

    /**
     * 错误码
     */
    private final String resultCode;

    /**
     * 错误描述
     */
    private final String resultMsg;

    EnumException(String resultCode, String resultMsg) {
        this.resultCode = resultCode;
        this.resultMsg = resultMsg;
    }

    public String getResultCode() {
        return resultCode;
    }

    public String getResultMsg() {
        return resultMsg;
    }
}
